package edu.wit.acl.service;


import com.baomidou.mybatisplus.extension.service.IService;
import edu.wit.acl.entity.Role;

import java.util.List;
import java.util.Map;

/**
 * <p>
 * 服务类
 * </p>
 *
 * @author testjava
 * @since 2020-01-12
 */
public interface RoleService extends IService<Role> {

    //根据用户获取角色数据
    Map<String, Object> findRoleByUserId(String userId);

    //根据用户分配角色
    void saveUserRoleRealtionShip(String userId, String[] roleId);

    List<Role> selectRoleByUserId(String id);

    Role selectByRoleId(String roleId);

    Role selectByRoleName(String roleName);

    List<String> selectUserIdsByRoleName(String roleName);

    String selectCorpIdByUserId(String userId);

    List<Role> selectByCompanyId(String companyId);

    String selectCompanyNameByCompanyId(String companyId);

    Role selectByRoleNameAndCompanyId(String roleName, String companyId);


}
